Copy
The Copy command is a request to copy an object or objects to a new location. The Finder version is similar to the standard application command described
in the AppleScript Language Guide, except that the Finder's Copy command
must include parameters.As shown in the syntax definition,
put
andinto
are synonyms forcopy
andto
. When you compile a script,put
andinto
are automatically changed tocopy
andto
.SYNTAX
( copy | put ) expression ( to | into ) referenceToObjectPARAMETERS
- expression
- The expression whose value is to be copied. If expression is a reference or a list of references, the Finder copies the objects specified by the references.
Class: Any class- referenceToObject
- A reference to the object to which to copy expression.
Class: ReferenceRESULT
A reference to the copied object or a list of references.EXAMPLE
This script copies two files and places them in a folder on another disk:
tell application "Finder" copy {file "Release Notes" of disk "My World", ¬ file "Report" of disk "My World"} to folder "Backups" of ¬ startup disk end tell